#include "org/rule.h"
#include "org/ruleio.h"
#include "org/organiser.h"
#include "frmrule.h"

#include "qrulemodel.h"
#include "qrulegroupmodel.h"
#include "qmatchedpathmodel.h"


#include <QtGui/QMainWindow>
#include <QModelIndex>
#include <QFileDialog>

using namespace Org;


#ifndef FRMMAIN_H
#define FRMMAIN_H

#include <QtGui/QMainWindow>

namespace Ui {
    class frmmain;
}

class frmmain : public QMainWindow {
    Q_OBJECT
public:
    frmmain(QWidget *parent = 0);
    ~frmmain();        

    void populate_table_rules();
    static void cb_populate_rule_groups();    

    void insert_new_rule(Rule) const;


public slots:
    void btnRunRules_clicked();
    void tblRulesClicked_showRule(QModelIndex);
    void btnIncomingDir_clicked();
    void btnExecute_clicked();
    void btnListRefresh_clicked();
    void mnuNewRule_clicked();


protected:
    void changeEvent(QEvent *e);

private:
    Ui::frmmain *ui;
};

#endif // FRMMAIN_H
